-
-
Notifications
You must be signed in to change notification settings - Fork 825
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CRM-21858: 'Merge All Contacts with the Same Address' doesn't consider Household replace individuals that share same address. #11901
Conversation
ping @lcdservices |
@monishdeb this isn't right. The distinguishing factor is not whether they share an address, but whether a household relationship exists.
Merge same address gives preference to the existence of a household relationship. It is intended as an extension of the "merge household" function -- it looks for contacts not connected by a household and merges them AND also merges via household. I think the confusion is with the help text:
The phrase "in which multiple individuals share an address" was not intended to be interpreted as referring to the share address functionality. It was intended to mean, if two individuals have the same address and have a household relationship, the household record will be exported. To put it another way -- the goal of these two tools is to allow orgs to collapse records down and reduce mailing costs. Merge household does that strictly -- there must be a household relationship present. Merge address does it more dynamically (extends the functionality) -- if a household record exists, we use that; but if it doesn't, we try to collapse/merge them down based on matching addresses. |
this would need a test |
5daf1dc
to
b61713b
Compare
@eileenmcnaughton @lcdservices I have updated the PR which is dependent on #11870 changes. The reason why I have to cherrpick the commit from previous, and do the change on the top of it. Also updated the description and added UT. Please have look :) |
@monishdeb ran some tests and this looks good -- contacts are now merged into households if those relationships exist. |
… Members into their Households" produces db error
jenkins test this please |
@monishdeb I'm going to close this one out until we have resolved #11870 I can't see myself being able to review either of them until we have gotten the code to a state of legibility so I feel these 2 have to be 'longer term projects' |
(as an aside - the trick to re-opening as opposed to creating new is to reopen before you force-push) |
Overview
Consider 3 contacts A,B, C where A and B individuals share same address. C is a household whose member is A. On export following is what is expected and how the current scenario works before the fix
Expected: 1 record which is C, A and B share the same address so that should be merged into 1 contact but then A is also a member of C so C take precedence over A. So at the end, only C should be exported.
Actual: 2 records i.e. combined record of (A & B), C (Incorrect)
Before
Contain 2 records as described
Actual
scenarioAfter
Export result contains Household C